Ceph1="10.10.9.47"
Ceph2="10.10.9.48"
Ceph3="10.10.9.49"
Ceph4="10.10.9.5"

a=1

for node in $Ceph2 $Ceph3 $Ceph4
do
    ssh $node "
        rm -rf check
        source /etc/profile
        cd $HOME
        if [ ! -d 'check' ]
        then
            git clone https://gitee.com/zhujerry/check.git
        else
            cd $HOME/check
            git pull;
        fi
        cd $HOME/check/src
        sed -i '9i Cluster = $a' ./main.go
        sed -i '10d' ./main.go
    " &
    let a=$a+1
done 
wait


git pull